/* -------------------------------------------------------------------------- */
/*                           Copyright 2024 NXP                               */
/*                            All rights reserved.                            */
/*                    SPDX-License-Identifier: BSD-3-Clause                   */
/* -------------------------------------------------------------------------- */

/* -------------------------------------------------------------------------- */
/*                                  Includes                                  */
/* -------------------------------------------------------------------------- */

#include <stdarg.h>
#include "fwk_platform_crypto.h"
#include "sss_crypto.h"

/* -------------------------------------------------------------------------- */
/*                               Private macros                               */
/* -------------------------------------------------------------------------- */

/* -------------------------------------------------------------------------- */
/*                         Private memory declarations                        */
/* -------------------------------------------------------------------------- */

/* -------------------------------------------------------------------------- */
/*                              Private functions                              */
/* -------------------------------------------------------------------------- */

/* -------------------------------------------------------------------------- */
/*                              Public functions                              */
/* -------------------------------------------------------------------------- */

int PLATFORM_InitCrypto(void)
{
    CLOCK_EnableClock(kCLOCK_Secsubsys);
    return 0;
}

int PLATFORM_TerminateCrypto(void)
{
    CRYPTO_DeinitHardware();
    return 0;
}

int PLATFORM_ResetCrypto(void)
{
    CRYPTO_ELEMU_reset();
    (void)CRYPTO_ReinitHardware();
    return 0;
}
